home *** CD-ROM | disk | FTP | other *** search
/ Turnbull China Bikeride / Turnbull China Bikeride - Disc 1.iso / HENSA / SCREENSAVER / LINEZ.ZIP / !Linez / !Help next >
Text File  |  1998-03-20  |  10KB  |  191 lines

  1. > !Linez.!Help
  2.  
  3.              LINEZ - A USER-CONFIGURABLE DESKTOP SCREENSAVER
  4.              ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  5.  
  6. INTRODUCTION
  7.  
  8. Linez is a desktop front-ended screensaver which bounces lines around the
  9. screen, fading them from one colour to another. The lines can either be
  10. straight or curved (bezier) and for speed the screensaver code itself is
  11. written in pure ARM assembler. This program requires 32k to execute.
  12.  
  13. This screensaver does not, however, work with the RISC OS screenblanker
  14. utility so this should be turned off. Also, in multitasking mode, naughty
  15. programs that use direct screen access without checking for screen output
  16. disabling, like Zap's flashing cursor or an active taskwindow, can cause
  17. wierd little bits to appear on the screen in odd places.
  18.  
  19. The basics are that clicking SELECT on the application on the iconbar icon
  20. opens the configuration window (which should be self-explanatory) and ADJUST
  21. starts the sceensaver (which has a default delay time of 30 seconds). Another
  22. way to start the screensaver is to move the mouse to the top-left corner of
  23. the screen and wait for 3 seconds. By default the screensaver runs in the
  24. current desktop mode. Move the mouse or press SHIFT to return to the desktop.
  25. NEW - Also responds to !CallerID.
  26.  
  27. Things can get REALLY fun when you have say five copies of the screensaver
  28. multitasking together - they will all start at the same time! For best
  29. results don't use reflection when using multiple copies.
  30.  
  31. LICENCE
  32.  
  33. This program is FREEWARE so may be used by all and distributed freely
  34. between individuals and by PD libraries and ftp/bbs etc. as long as this is
  35. not done for profit and the application remains complete and unaltered.
  36.  
  37. DETAILED INSTRUCTIONS
  38.  
  39. Double-click on the !Linez icon in the filer window (why I am bothering to
  40. say this I have no idea...) and the program will install itself on the icon
  41. bar, unless of course you've get the hide icon option set. If you always want
  42. to have multiple copies loaded up then change the !Run file to include the
  43. correct number of Filer_Run's.
  44.  
  45. Clicking MENU on the icon bar icon brings up a menu with five entries: Info,
  46. Start, Configure, Help ..., Quit. Info leads to an information box thingy
  47. (yes I know 'Totally amazing screensaver' sounds really pretentious but no
  48. one takes these purpose fields seriously anyway). Start is identical to
  49. an ADJUST click on the icon bar icon, Configure to a SELECT click. Help ...
  50. loads this particular file into the nearest friendly text editor. Quit
  51. terminates execution of the proggy (not that you'd want to do that). 
  52. NEW - Hold down Alt as you quit from icon bar menu or Task Manager to close
  53. all copies.
  54.  
  55. SELECT opens the configuration window as mentioned before. The option sets
  56. are described below:
  57.  
  58. Screensaver Options - The screensaver can run in the current desktop mode or
  59. be given an alternative. Mode number allows RISC OS 3.1 users to specify a
  60. mode number; a 256 colour one is preferable like mode 15 (CGA) or mode 28
  61. (VGA). Mode string allows RISC OS 3.5+ users to specify resolution and colour
  62. depth exactly (it doesn't work on RISC OS 3.1 so don't bother to try). If the
  63. mode number is unavailable/invalid then the current desktop mode is used. The
  64. visible advantage of 32K colours over 256 is small and of 16M over 32K even
  65. less! Incidentally, a CMYK palette is used in a 4 colour mode which looks
  66. better than RGB IMHO, and a custom one used in a 16 colour mode. It is
  67. possible to set whether the screensaver multitasks while operating; this can
  68. slow the screensaver down especially if file operations are going on while
  69. it's trying to draw lines all over the screen. If multiple copies are loaded
  70. then only ones with the multitasking option set will start up. Whether or not
  71. an icon is put on the icon bar can be set for those of you who don't like
  72. getting cluttered. If you hold down one of the Alt keys while the program is
  73. loading you get an icon there anyway. The sleep/no-sleep corners work by
  74. checking if the pointer is at the top-left or top-right of the screen and
  75. starting or disabling the screensaver accordingly. These can be turned on or
  76. off.
  77.  
  78. Time Delay - This sets how long a period of desktop inactivity is required to
  79. trigger the screensaver. Any value from one second to an hour (3600 seconds)
  80. can be entered in the custom box if you don't like the presets.
  81.  
  82. Linez - This option sets whether straight or bezier lines are used, and the
  83. quality of the bezier lines. The number 2 raised to the power quality is how
  84. many straight lines make up the bezier curve - with quality 5 there are 32
  85. for example. The delay between lines is measured in centiseconds. If the
  86. lines take longer to draw than the delay then this delay time is ignored.
  87.  
  88. Reflection - The points for one line only are calculated but these can be
  89. mirrored to produce interesting effects. Reflect diagonally means in the line
  90. y=-x. Reflect three ways means this and in the x- and y-axes.
  91.  
  92. Movement - This provides the most room for experimentation! Maximum velocity
  93. is measured in OS units per second (a VGA screen is 1280 by 960 OS units) and
  94. maximum acceleration in 1/16ths of an OS unit per second squared (!) Colour
  95. fading is based on an RGB colour cube: intensities 64-255 are used for the
  96. red, green and blue components. Acc change every and Fade change every is the
  97. average number of lines between a change in the acceleration or fading rate.
  98.  
  99. The Demo button allows you to view the effects of any changes without
  100. storing them and Cancel will reset any values you have not OK'd. OK and Save
  101. both store the changes, but as you might expect Save creates a file called
  102. Config inside the application ready for when you reload. Click ADJUST on any
  103. of these buttons and the window stays open.
  104.  
  105. If you click ADJUST on the iconbar icon the screensaver is started
  106. immediately but unlike pressing Demo any un-OK'd changes are not taken into
  107. account. It in effect shortens the delay time to zero. Any movement of the
  108. mouse or keypress will return you to the desktop, however I recommend you
  109. move mouse or press SHIFT in multitasking mode so you don't end up typing in
  110. stuff where you didn't want it.
  111.  
  112. A FEW IDEAS
  113.  
  114. Here are a few values to give you a few ideas for experimenting with. They
  115. were obtained using MODE 28, delay time of 4 and bezier line quality of 5 in
  116. singletasking mode on my trusty A3010.
  117.  
  118.  *-----------------------------------------------------------------------*
  119.  | Type of line      |         STRAIGHT        |          BEZIER         |
  120.  |-------------------+-------------------------+-------------------------|
  121.  | Number of lines   | 25  | 50   | 35  | 40   | 70   | 10  | 20   | 15  |
  122.  | Reflection        | all | none | x   | y=-x | none | y   | y=-x | all |
  123.  | Max velocity      | 16  | 32   | 24  | 20   | 16   | 64  | 28   | 20  |
  124.  | Max acceleration  | 32  | 4    | 8   | 0    | 2    | 16  | 8    | 4   |
  125.  | Max fade          | 32  | 8    | 20  | 12   | 4    | 64  | 24   | 20  |
  126.  | Acc change every  | 50  | 100  | 200 | 500  | 100  | 10  | 160  | 15  |
  127.  | Fade change every | 100 | 250  | 75  | 120  | 50   | 50  | 80   | 60  |
  128.  *-----------------------------------------------------------------------*
  129.  
  130. HOW IT WORKS
  131.  
  132. Each straight line requires two reference points (each end in other words)
  133. and each bezier curve needs four. Each point has both an x and y position,
  134. velocity and acceleration. Every frame, the velocities are added to the
  135. positions and the accelerations to the velocities. The illusion of movement
  136. is given by blanking out one of the previous lines leaving the correct
  137. number still on screen. The colour is stored as 24-bit RGB with the red,
  138. green and blue elements changing at a constant rate. The colour change rates
  139. and accelerations are changed to new random values every so often. The
  140. centre of the screen is set to be the origin so reflection is simply done by
  141. changing the sign of the x, y or both co-ordinates and drawing the
  142. line/curve again. The colour is set using the ColourTrans module to pick the
  143. closest match and dithering is used. This program uses an unallocated wimp
  144. message &C4C5A in multiple copies mode.
  145.  
  146. SPEED IMPROVEMENTS (ARM2/250)
  147.  
  148. The calls to the operating system to draw the lines can be made MUCH faster
  149. on RISC OS 3.1 by speeding up the ROM's. To do this you need to type
  150. SYS "OS_UpdateMEMC",160,240 at the BASIC prompt (or create a BASIC program
  151. and run it). *RMFaster ColourTrans may have some effect. Alternatively, to
  152. increase speed try using less reflection and lower bezier line quality and
  153. not trying to multitask 99 copies together - or buy a RiscPC!
  154.  
  155. THE AUTHOR
  156.  
  157. A humble penniless physics student slaving away over his Arc for hours on
  158. end when there are far more exciting things on offer .... (only joking!)
  159.  
  160. Richard Spencer            phy7rs@leeds.ac.uk (until May 2001)
  161.  
  162. Mortain House
  163. Bodington Hall
  164. Otley Road
  165. LEEDS
  166. LS16 5PT
  167.  
  168. (until June 1998)
  169.  
  170. RECENT CHANGES
  171.  
  172. Version         Stuff Done
  173.  
  174. 1.50 04 Nov 97  Option to hide icon bar icon (for Clive Semmens)
  175.  
  176. 1.55 08 Nov 97  Sleep and no-sleep corners added (thanx Reg French)
  177.                 Config window changed (improved hopefully)
  178.         
  179. 1.60 26 Feb 98  Screensaver ends when message &4DEC0 broadcast which is when
  180.                 !CallerID sees an incoming call (John and Christina West)
  181.                 Alt-Quit closes all currenly loaded copies
  182.                 !RunImage sets its own slot size so Filer_Run can be used
  183.                 In first line M%=max number of lines, m%=message id
  184.                 
  185. 1.61 20 Mar 98  Attempted to cure missed typed characters when used in
  186.         combination with Mauser. Uses Wimp_PollIdle p%=delay in cs
  187.                 
  188. Future - rewrite the entire program to create relocatable module in the same
  189. way the screensaver 'Out to Lunch' does...... ?
  190.  
  191.